package cn.kjcoder.orderServer.feign;

import cn.kjcoder.orderServer.feign.fallBack.ProductFeignFallBack;
import cn.kjcoder.productServer.domain.Product;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @author hkj
 * @email 1349091387@qq.com
 * @date 2021/12/22
 * 源码允许修改，并且本人十分乐意有 大佬 来对代码进行 随 意 调 教
 **/
@FeignClient(name = "product-service",fallback = ProductFeignFallBack.class)
public interface ProductFeignApi {

    @RequestMapping("/product/get")
    public Product findById(@RequestParam("id") Long id);
}
